/*
 * Publisher.java
 *
 * Created on May 12, 2006, 2:45 AM
 *
 * To change this template, choose Tools | Options and locate the template under
 * the Source Creation and Management node. Right-click the template and choose
 * Open. You can then make changes to the template in the Source Editor.
 */

/**
 *
 * @author jtma
 */

import java.sql.SQLException;
import java.io.File;
import java.io.FileOutputStream;
import java.io.PrintWriter;
import java.util.Vector;
import java.util.regex.*;
import java.util.StringTokenizer;


public class Publisher {
    
    private String _outputfile;
    
    /** Creates a new instance of Publisher */
    public Publisher(String filename) {
        _outputfile = filename;
    }

    public void clear()
    {
        new File(_outputfile).delete();
    }
    
    public void dump(String str)
    {
        try {
            PrintWriter pw = new PrintWriter(new FileOutputStream(_outputfile, true));
            pw.println(str);
            pw.close();
        }
        catch (Exception e) {
            e.printStackTrace();
            System.exit(1);
        }

    }
}
